<%@ page contentType="text/html;charset=UTF-8" %>
<%@ include file="/WEB-INF/views/include/taglib.jsp"%>
<html>
<head>
	<title><spring:message code="template.manage"/></title>
	<meta name="decorator" content="default"/>
    <style>
        .mgl300{margin-left: 300px;}
        .mgl400{margin-left: 400px;}
        .tu-con{font-size: 40px;margin-top: 140px;}
    </style>
</head>
<body>
	<ul class="nav nav-tabs">
		<li>
            <a href="${ctx}/templet/eleTemplet/">
                <spring:message code="template.list"/>
            </a>
        </li>
		<li class="active">
            <a href="${ctx}/templet/eleTemplet/show?id=${eleTemplet.id}">
                <shiro:hasPermission name="templet:eleTemplet:edit">
                    <c:if test="${not empty eleTemplet.id}">
                        <spring:message code="template.modify"/>
                    </c:if>
                    <c:if test="${empty eleTemplet.id}">
                        <spring:message code="template.add"/>
                    </c:if>
                </shiro:hasPermission>
                <shiro:lacksPermission name="templet:eleTemplet:edit">
                    <spring:message code="template.info"/>
                </shiro:lacksPermission>
            </a>
        </li>
	</ul>
        <div class="ul-form tu-con mgl300">
            <c:if test="${eleTemplet.delFlag == '0'}">
                创建成功，可立刻发布至设备
            </c:if>
            <c:if test="${eleTemplet.delFlag == '2'}">
                创建成功，等待区域管理员审核
            </c:if>
        </div>
        <div class="mgl400" style="float: left;margin-top: 40px;">
            <shiro:hasPermission name="templet:eleTemplet:view">
                <a href="${ctx}/templet/eleTemplet/download?id=${eleTemplet.id}" class="btn btn-primary" style="margin-left: 30px;"><spring:message code="download"/></a>
            </shiro:hasPermission>
            <shiro:hasPermission name="templet:eleTemplet:publish">
            <a href="${ctx}/templet/eleTemplet/applypublish?id=${eleTemplet.id}" class="btn btn-primary" style="margin-left: 30px;">申请发布</a>
            </shiro:hasPermission>
        </div>
</body>
</html>